/* eslint-disable no-undef */
const inquirer = require("inquirer");

module.exports = {
  async toastCreateViewType() {
    const viewType = await inquirer.prompt([
      {
        type: "list",
        message: "😋 您要创建以下哪种文件模板?",
        name: "type",
        default: "空页面",
        choices: ["空页面", "列表页"],
      },
    ]);
    return viewType;
  },
  async toastFileName() {
    const fileName = await inquirer.prompt([
      {
        type: "input",
        message: "🤔 请输入您要创建的路径: ",
        name: "path",
        default: "",
      },
      {
        type: "input",
        message: "🤔 请输入您要创建的名字: ",
        name: "name",
        default: "View",
      },
    ]);
    return fileName;
  },
};
